package com.yonyou.cyxdms.basedata.service.scheduler;

import com.xxl.job.core.biz.model.ReturnT;
import com.xxl.job.core.handler.annotation.XxlJob;
import com.yonyou.cyxdms.basedata.service.service.feign.SendVehiclePriceService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import java.util.HashMap;
import java.util.Map;

/**
 * Context
 * 定时任务 产品主数据价格下发价格
 * Author weikaichen
 * Date 2022-05-24
 */
@Component
@Slf4j
public class WholesProductPriceSendJob {
    @Autowired
    private SendVehiclePriceService sendVehiclePriceService;


    @XxlJob(value = "wholesProductPriceSendJob")
    public ReturnT<String> process(String param) throws Exception {
    	log.info("===================下发车辆价格开始===================");
        sendVehiclePriceService.sendVehiclePriceToDms();
        sendVehiclePriceService.updatePrice();
        log.info("===================下发车辆完成完成===================");
        return ReturnT.SUCCESS;
    }


}

